<?php
extract($HTTP_POST_VARS, EXTR_PREFIX_SAME, "");
extract($HTTP_GET_VARS, EXTR_PREFIX_SAME, "");
extract($HTTP_SESSION_VARS, EXTR_PREFIX_SAME, "");
extract($HTTP_COOKIE_VARS, EXTR_PREFIX_SAME, "");
extract($HTTP_SERVER_VARS, EXTR_PREFIX_SAME, "");
extract($HTTP_POST_FILES, EXTR_PREFIX_SAME,"");
$login_host = 'localhost';
$login_user = 'test_user';
$login_pwd 	= 'test12345';
$login_db 	= 'uniaimlogin';
$dbp		=	@mysql_connect($login_host, $login_user, $login_pwd);  //DB connect
@mysql_select_db($login_db,$dbp) or die("db connect err");
mysql_query("SET NAMES UTF8");

function MDBarray($qry)
{
	global $dbp;
	$result = @mysql_query($qry, $dbp) or die("Qry Err. : $qry");
	return mysql_fetch_array($result);
}

// mysql_query function
function MDBquery($qry)
{
	global $dbp;
	return mysql_query($qry,$dbp);
}


// mysql_num_rows function
function MDBnumrows($qry) {
	global $dbp;
	$result = mysql_query($qry,$dbp);
	return mysql_num_rows($result);
}
?>